package v1

import "github.com/gogf/gf/v2/frame/g"

type IndexReq struct {
	g.Meta `path:"/" method:"get" sm:"首页" tags:"管理ppt"`
	Page   int `json:"page" in:"query" d:"1"  v:"min:0#分页号码错误"     dc:"分页号码，默认1"`
	Size   int `json:"size" in:"query" d:"10" v:"max:50#分页数量最大50条" dc:"分页数量，最大50"`
}

type IndexRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type AddAndUpdateReq struct {
	g.Meta `path:"/save" method:"post" sm:"添加或者更新" tags:"管理ppt"`
	Id     int    `json:"id" dc:"ID"`
	Name   string `json:"name" v:"required" dc:"名称"`
	Order  string `json:"order" v:"required" dc:"排序"`
}

type AddAndUpdateRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type DelReq struct {
	g.Meta `path:"/delete" method:"delete" sm:"删除" tags:"管理ppt"`
	Id     int `json:"id" v:"required" dc:"ID"`
}

type DelRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type ContentListReq struct {
	g.Meta `path:"/content/{tid}" method:"get" sm:"content页面" tags:"管理ppt"`
	Tid    int `json:"tid" dc:"tags的id"`
	Page   int `json:"page" in:"query" d:"1"  v:"min:0#分页号码错误"     dc:"分页号码，默认1"`
	Size   int `json:"size" in:"query" d:"10" v:"max:50#分页数量最大50条" dc:"分页数量，最大50"`
}

type ContentListRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type ContentAddAndUpdateReq struct {
	g.Meta  `path:"/content/save" method:"post" sm:"添加或者更新content" tags:"管理ppt"`
	Id      int    `json:"id" dc:"ID"`
	Name    string `json:"name" v:"required" dc:"名称"`
	Content string `json:"content" v:"required" dc:"内容"`
	Tags    int    `json:"tags" v:"required" dc:"ppt名称"`
	Order   string `json:"order" v:"required" dc:"排序"`
}

type ContentAddAndUpdateRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type ContentDelReq struct {
	g.Meta `path:"/content/delete" method:"delete" sm:"删除content" tags:"管理ppt"`
	Id     int `json:"id" v:"required" dc:"ID"`
}

type ContentDelRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type ShowReq struct {
	g.Meta `path:"/show/{id}" method:"get" sm:"首页" tags:"管理ppt"`
	Id     int `json:"id" dc:"ID"`
	Page   int `json:"page" in:"query" d:"1"  v:"min:0#分页号码错误"     dc:"分页号码，默认1"`
}

type ShowRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

// 启用ppt页面上class或者id的点击功能
type DianjiIndexReq struct {
	g.Meta `path:"/dianji" method:"get" sm:"功能首页" tags:"管理ppt"`
}

type DianjiIndexRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type DelDianjiReq struct {
	g.Meta `path:"/dianji/delete" method:"delete" sm:"删除class或者id" tags:"管理ppt"`
	Id     int `json:"id" v:"required" dc:"ID"`
}

type DelDianjiRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}

type SaveDianjiReq struct {
	g.Meta    `path:"/dianji/save" method:"post" sm:"添加或者修改class或者id" tags:"管理ppt"`
	Id        int    `json:"id" dc:"ID"`
	ClassORid string `json:"classorid" v:"required" dc:"classORid"`
}

type SaveDianjiRes struct {
	g.Meta `mine:"text/html" exapmle:"string"`
}
